package cn.datawin;

public class MainRun {

	public static void main(String[] args) {

		CooClient coo = new CooClient();
		coo.start(Rule_Baidu.class);
		
		new Rchuli(coo).doResult();
	}
}

class Rchuli {
	CooClient coo;

	public Rchuli(CooClient coo) {
		this.coo = coo;
	}
	
	public void doResult(){
		while(true){
			try {
				Thread.sleep(3000);
			} catch (InterruptedException e) {}
			Result re =  Collectionss.list.poll();
			if(re!= null){
				CooService service =  (CooService) coo.getService("123456");
				service.dooResult(re);
			}
		}
		
	}

}
